package base.IO流;

import base.集合.Treemap;

import java.io.*;
import java.util.TreeMap;

public class 出师表排序 {
    public static void main(String[] args) throws IOException {
        File scr = new File(".\\src\\base\\IO流\\csb.txt");
        BufferedReader br = new BufferedReader(new FileReader(scr));

        int nu = 0;
        while(br.readLine() != null){
            nu++;
        }
        br.close();
        br = new BufferedReader(new FileReader(scr));
        String[] arr = new String[nu];
        for (int i = 0; i < nu; i++) {
            arr[i] = br.readLine();
        }
        TreeMap<Integer,String> treeMap = new TreeMap<>();
        for(String s : arr){
            String[] a = s.split("\\.");
            treeMap.put(Integer.parseInt(a[0]),a[1]);
        }
        for (int i = 0; i < nu; i++) {
            System.out.println(treeMap.get(i+1));
        }

    }
}
